package com.wolfpire.system.model;

import java.io.Serializable;
import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

import org.springframework.format.annotation.DateTimeFormat;

import com.fasterxml.jackson.annotation.JsonFormat;
/**
 * 用户组实体类
 * @author Administrator
 *
 */
@Entity
@Table(name = "t_sm_usergroup")
public class UserGroup implements Serializable {
	private static final long serialVersionUID = -1289062153270697592L;

	@Id
	@GeneratedValue(strategy = GenerationType.IDENTITY)
	@Column(name = "id", unique = true, nullable = false, length = 32)
	private Long id;        //主键Id
	
	@Column(name = "name", length = 75)
	private String name;   //名称
	
	@Column(name = "remark", length = 75)
	private String remark; //备注
	
	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "create_time")
	@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")  
	@JsonFormat(pattern="yyyy-MM-dd HH:mm:ss",timezone = "GMT+8") 
	private Date createTime = new Date();//创建时间[注册时间]

	public UserGroup() {
		super();
		// TODO Auto-generated constructor stub
	}

	public UserGroup(String name) {
		super();
		this.name = name;
	}

	public UserGroup(Long id, String name, String remark) {
		super();
		this.id = id;
		this.name = name;
		this.remark = remark;
	}



	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public Date getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}

	public String getRemark() {
		return remark;
	}

	public void setRemark(String remark) {
		this.remark = remark;
	}
	
	
	
	

}
